<template>
  <div class="main-nav">
    <navhead></navhead>
    <div class="desc">
      <info></info>
      <div class="teacher-notice">
        <h3>教学公告</h3>
        <p>{{teacherTip}}</p>
      </div>
    </div>

  </div>
</template>

<script>
import Info from '../common/userinfo'
import Navhead from '../common/navhead'
export default {
  components: {
    Info,
    Navhead
  },
  data () {
    return {
      teacherTip: "暂无"
    }
  },
  mounted () {
    eventBus.$on('setTeacherTip', (val) => {
      this.teacherTip = val
    })
  },
  beforeDestroy () {
    eventBus.$off('setTeacherTip')
  },

}
</script>
<style lang="scss">
.main-nav {
  background: #e8ebf2;
  .desc {
    display: flex;
    margin: 0 auto;
    width: 90vw;
    height: 350px;
    padding: 35px 5vw;
    box-sizing: border-box;
    overflow: hidden;
    box-shadow: 0 0 20px #000;
    border-radius: 10px;
    background: url(../../assets/img/banner.png) no-repeat center center;
    background-size: 100% 100%;
    .teacher-notice {
      box-sizing: border-box;
      max-width: 50vw;
      height: 245px;
      margin: 35px 50px;
      h3 {
        margin-bottom: 30px;
        font-size: 36px;
        color: #e8f1f8;
      }
      p {
        line-height: 32px;
        font-size: 16px;
        color: #e8f1f8;
      }
    }
  }
}
</style>